package org.reliablesource.prism.gef.editor.parts;

import org.eclipse.gef.GraphicalEditPart;
import org.reliablesource.prism.gef.editor.figures.PrismPolylineConnection;

/**
 * 
 * WireEndpointEditPolicy.java 
 *
 * Copyright (c) 2006, Reliable Source, Inc. All Rights Reserved
 * 
 * Created on: Apr 12, 2006
 * 
 * @author Dennis Park <a
 *         href="mailto:dennis.park@gmail.com">dennis.park@gmail.com</a>
 * 
 */
public class WireEndpointEditPolicy extends
		org.eclipse.gef.editpolicies.ConnectionEndpointEditPolicy {

	protected void addSelectionHandles() {
		super.addSelectionHandles();
		getConnectionFigure().setLineWidth(2);
	}

	protected PrismPolylineConnection getConnectionFigure() {
		return (PrismPolylineConnection) ((GraphicalEditPart) getHost()).getFigure();
	}

	protected void removeSelectionHandles() {
		super.removeSelectionHandles();
		getConnectionFigure().setLineWidth(0);
	}

}
